﻿<%@ Page Title="Consulta de Proveedor" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="consulta_proveedor.aspx.vb" Inherits="Storexpress.consulta_proveedor" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .style2
        {
            width: 76%;
            height: 377px;
        }
        .style4
        {
            font-family: verdana;
            font-size: large;
            font-weight: bold;
        }
        .style15
        {
            font-family: verdana;
            font-size: large;
            font-weight: bold;
            }
        .style24
     {
         font-family: verdana;
         font-size: large;
     }
     .style25
     {
         height: 30px;
            text-align: left;
            width: 515px;
        }
     .style26
     {
        text-align: right;
        height: 39px;
    }
     .style27
     {
         width: 97%;
     }
     .style28
     {
         width: 443px;
            text-align: left;
        }
    .style35
    {
        height: 60px;
        width: 140px;
    }
    .style36
    {
        text-align: right;
    }
    .style37
    {
        width: 89%;
            height: 42px;
        }
    .style38
    {
        width: 347px;
        text-align: right;
    }
    .style39
    {
        text-align: left;
    }
    .style40
    {
        height: 130px;
        text-align: left;
    }
    .style41
    {
        height: 82px;
            width: 515px;
        }
    .style42
    {
        width: 467px;
        height: 30px;
    }
        .style43
        {
            height: 40px;
        }
        .style45
        {
            width: 467px;
            height: 82px;
            text-align: left;
        }
        .style46
        {
            height: 114px;
            text-align: left;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <table class="style2" align="center">
        <tr>
            <td class="style43" 
                
                style="font-size: x-large; font-weight: 700; color: #FFFFFF; text-align: center;" 
                colspan="2">
                </td>
        </tr>
        <tr>
            <td class="style43" 
                
                style="font-size: x-large; font-weight: 700; color: #FFFFFF; text-align: center;" 
                colspan="2">
                <asp:Label ID="L_titulo" runat="server" CssClass="style24" 
                    Text="Consulta Proveedor"></asp:Label>
            </td>
        </tr>
        <tr>
            <td class="style42" 
                
                style="font-size: x-large; font-weight: 700; color: #FFFFFF; text-align: right;">
                <asp:Label ID="L_nombre" runat="server" style="font-family: verdana; font-size: large;" 
                    Text="Nit:"></asp:Label>
            </td>
            <td class="style25">
                <asp:TextBox ID="TB_nit" runat="server" Width="180px" Height="20px" 
                    MaxLength="12" 
                    
                    style="font-family: verdana; font-size: large; font-weight: 700; margin-left: 0px;"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="style26" 
                style="font-size: x-large; font-weight: 700; color: #FFFFFF" colspan="2">
                <table class="style37" align="center">
                    <tr>
                        <td class="style38">
                <asp:Button ID="BT_buscar" runat="server" Text="Buscar" CssClass="style15" 
                    Height="28px" Width="105px" BackColor="#999999" />
                        </td>
                        <td class="style39">
                <asp:Button ID="BT_borrar" runat="server" Text="Borrar" CssClass="style15" 
                    Height="27px" Width="100px" BackColor="#999999" />
                        </td>
                    </tr>
                </table>
                </td>
        </tr>
        <tr>
            <td class="style40" 
                style="font-size: x-large; font-weight: 700; color: #FFFFFF" colspan="2">
                <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
                    DataKeyNames="NIT_PROVEEDOR" DataSourceID="SqlDataSource1" 
                    EmptyDataText="No hay registros de datos para mostrar." 
                    style="font-size: large">
                    <Columns>
                        <asp:BoundField DataField="NIT_PROVEEDOR" HeaderText="Nit" ReadOnly="True" 
                            SortExpression="NIT_PROVEEDOR" />
                        <asp:BoundField DataField="NOMBRE_PROVEEDOR" HeaderText="Nombre" 
                            SortExpression="NOMBRE_PROVEEDOR" />
                        <asp:BoundField DataField="DIREC_PROVEEDOR" HeaderText="Dirección" 
                            SortExpression="DIREC_PROVEEDOR" />
                        <asp:BoundField DataField="E_MAIL" HeaderText="E_mail" 
                            SortExpression="E_MAIL" />
                        <asp:BoundField DataField="CONTACTO" HeaderText="Contacto" 
                            SortExpression="CONTACTO" />
                        <asp:BoundField DataField="NUMERO_TELEFONO" HeaderText="Número Telefónico" 
                            SortExpression="NUMERO_TELEFONO" />
                    </Columns>
                </asp:GridView>
                <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:storexpressConnectionString4 %>" 
                    DeleteCommand="DELETE FROM [SSPROVEEDOR] WHERE [NIT_PROVEEDOR] = @NIT_PROVEEDOR" 
                    InsertCommand="INSERT INTO [SSPROVEEDOR] ([NIT_PROVEEDOR], [NOMBRE_PROVEEDOR], [DIREC_PROVEEDOR], [E_MAIL], [CONTACTO], [NUMERO_TELEFONO]) VALUES (@NIT_PROVEEDOR, @NOMBRE_PROVEEDOR, @DIREC_PROVEEDOR, @E_MAIL, @CONTACTO, @NUMERO_TELEFONO)" 
                    ProviderName="<%$ ConnectionStrings:storexpressConnectionString4.ProviderName %>" 
                    SelectCommand="SELECT [NIT_PROVEEDOR], [NOMBRE_PROVEEDOR], [DIREC_PROVEEDOR], [E_MAIL], [CONTACTO], [NUMERO_TELEFONO] FROM [SSPROVEEDOR]" 
                    UpdateCommand="UPDATE [SSPROVEEDOR] SET [NOMBRE_PROVEEDOR] = @NOMBRE_PROVEEDOR, [DIREC_PROVEEDOR] = @DIREC_PROVEEDOR, [E_MAIL] = @E_MAIL, [CONTACTO] = @CONTACTO, [NUMERO_TELEFONO] = @NUMERO_TELEFONO WHERE [NIT_PROVEEDOR] = @NIT_PROVEEDOR">
                    <DeleteParameters>
                        <asp:Parameter Name="NIT_PROVEEDOR" Type="Int32" />
                    </DeleteParameters>
                    <InsertParameters>
                        <asp:Parameter Name="NIT_PROVEEDOR" Type="Int32" />
                        <asp:Parameter Name="NOMBRE_PROVEEDOR" Type="String" />
                        <asp:Parameter Name="DIREC_PROVEEDOR" Type="String" />
                        <asp:Parameter Name="E_MAIL" Type="String" />
                        <asp:Parameter Name="CONTACTO" Type="String" />
                        <asp:Parameter Name="NUMERO_TELEFONO" Type="Int32" />
                    </InsertParameters>
                    <UpdateParameters>
                        <asp:Parameter Name="NOMBRE_PROVEEDOR" Type="String" />
                        <asp:Parameter Name="DIREC_PROVEEDOR" Type="String" />
                        <asp:Parameter Name="E_MAIL" Type="String" />
                        <asp:Parameter Name="CONTACTO" Type="String" />
                        <asp:Parameter Name="NUMERO_TELEFONO" Type="Int32" />
                        <asp:Parameter Name="NIT_PROVEEDOR" Type="Int32" />
                    </UpdateParameters>
                </asp:SqlDataSource>
                </td>
        </tr>
        <tr>
            <td class="style46" 
                style="font-size: x-large; font-weight: 700; color: #FFFFFF" colspan="2">
                </td>
        </tr>
        <tr>
            <td class="style45" 
                style="font-size: x-large; font-weight: 700; color: #FFFFFF">
                </td>
            <td class="style41">
            </td>
        </tr>
        </table>
    <table class="style27">
        <tr>
            <td class="style28" valign="bottom">
    <asp:Button ID="BT_atras" runat="server" Text="Atrás" CssClass="style4" 
                    Height="27px" Width="100px" BackColor="#999999" />
            </td>
            <td class="style36"><img src="imagenes/systemsoft.png" class="style35" /></td>
        </tr>
    </table>
</asp:Content>
